#!/bin/sh
cat /var/log/manticore/query.log | LANG=C sed '/ (0,[0-9][0-9]\+)\] \[/!d; /_index\] *$/d; s/\[... \(...\)  \?\([0-9]\+\) [0-9.:]\+ \([0-9]\+\)\].*\] \[\([a-z]\+\)\(_main\)\?_index[^]]*\] \?\(.*\)$/\2 \1 \3,\4,\6/'
